﻿<%@ WebService Language="C#" Class="ViewCINoMatchFound_WS" %>

using System;
using System.Web;
using System.Web.Services;
using System.Web.Services.Protocols;
using System.Web.Script.Services;

using System.Collections;
using CE.User;
using CE.Global;
using CE.Database;
using CE.CarInsurance;

[WebService(Namespace = "http://tempuri.org/")]
[WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]
[ScriptService]
// To allow this Web Service to be called from script, using ASP.NET AJAX, uncomment the following line. 
// [System.Web.Script.Services.ScriptService]
public class ViewCINoMatchFound_WS  : System.Web.Services.WebService {

    [WebMethod]
    public string SaveCustomerDetailRemark(string CustomerId, string Remark)
    {
        try
        {
            if (Remark.Trim() == "")
                return "";

            MyDatabase _db = new MyDatabase();
            string strUpdate = "Update tblCEContact SET OtherContact1 = @OtherContact1 Where RefCEUserID = @CustomerID";
            SortedList _paraList = new SortedList();
            _paraList.Add("@OtherContact1", HttpUtility.HtmlEncode(Remark));
            _paraList.Add("@CustomerID", CustomerId);
            int _affRow = _db.ExecuteNonSqlStatement(strUpdate, _paraList);
            if (_affRow > 0)
            {
                return "Saved Successfully.";
            }
            else
                return "Error.";
        }
        catch (Exception Ex)
        {
            return Ex.Message;
        }
    }
    
    
}

